from DrissionPage._pages.chromium_page import ChromiumPage

from dp_pligin.hook.request_hook import SetRequestResponse

page = ChromiumPage()
with open('index1.js', 'r', encoding='utf-8') as file:
    response = file.read()
    print(response)
arr = [{
    'url': 'https://n.sinaimg.cn/finance/blackcat/pc/js/index.js?v=1.6.66',
    'response': response
}]
SetRequestResponse(page, arr)
page.get('https://tousu.sina.com.cn/')
